1. Field of the Invention
The present invention relates to an interface circuit between a logic sensor and an isolation barrier of a logic input of a processing circuit. The present invention generally applies to input/output circuits of logic processing circuits. These are, for example, input/output circuits of programmable controllers or the like.
2. Discussion of the Related Art
Logic inputs of processing circuits are most often intended to detect a logic state transmitted by a sensor, for example, a two-point sensor, a three-point sensor, a proximity switch or the output of a relay. The data are collected by a system powered by a D.C. voltage. A low logic level is generally represented by the most negative voltage of the power supply (generally, 0 volt) and a high logic level is most often represented by the most positive voltage (Vcc).
FIG. 1 schematically and partially shows a first conventional example of an interface circuit 1 of the type to which the present invention applies. A sensor 3 most often formed of a switch 31 is supplied by a voltage V, provided, for example, by a battery 4 or a D.C. power supply. The reference voltage of supply voltage 4 is common with that of interface circuit 1. In the example of FIG. 1, circuit 1 is formed by means of passive discrete elements, more specifically a bridge of resistors R, R1, R2 filtered at the output by a capacitor C. In other words, an electrode of capacitor C and a terminal of resistor R2 are connected to reference terminal 5 of application of voltage V. Sensor 3 is connected in series with generator 4 between terminal 5 and an input terminal 6 of the interface circuit corresponding to a first terminal of resistor R1. The other terminal of resistor R1 is connected to the second terminal of resistor R2 and to the second electrode of capacitor C defining an output terminal 7 of interface circuit 1. Most often, a protection resistor R is interposed between sensor 3 and terminal 6. Capacitor C is in parallel with a galvanic isolation element, in this example an optocoupler 2. Optocoupler 2 is formed of a photodiode 8 controlling a switch 9. The two terminals of photodiode 8 are connected to the electrodes of capacitor C while the two terminals of switch 9 are connected to the inputs of processing unit 10, which is partially shown and not described in detail. In the circuit of FIG. 1, the control of optocoupler 2 is proportional to the input current of the interface circuit, that is, to the current in resistor R. When switch 31 is off, the photodiode is not supplied and switch 9 is off. When switch 31 is on, a current flows through resistors R, R1, and R2. The voltage filtered across capacitor C biases photodiode 8 which thus turns switch 9 on.
FIG. 2 shows a second conventional example of an interface circuit 11 made in integrated form. As in FIG. 1, sensor 3 is in series with a supply voltage source 4 and a protection resistor R. Interface circuit 11, partially shown, includes a zener diode D12 connected between positive input terminal 6 of circuit 11 and reference terminal 5. A current source 13 is connected in parallel with diode D12 having its anode on the side of terminal 5. Terminal 6 is connected to the inverting input of an amplifier 14, the non-inverting input of which receives a reference current Iref. The output of amplifier 14 forms the output terminal of interface circuit 11 towards isolation barrier 2, for example, an optocoupler (not shown). The function of current source 13 is to provide an impedance matching at the input of amplifier 14 while diode D12 is used to limit this input voltage. According to whether the switch included in sensor 3 is on or off, amplifier 14 assembled as a comparator outputs a zero voltage or a voltage corresponding to its own supply voltage (that is, voltage V).
FIG. 3 shows a third conventional example of an interface circuit 15. In this example, a zener diode D12 is connected to input terminals 6 and 5 of the interface circuit which, as previously, are interconnected by protection resistor R, sensor 3, and voltage source 4 in series. A filtering capacitor C is arranged in parallel with optocoupler 2. The most positive terminal corresponding to a first electrode of capacitor C is connected to the cathode of zener diode D12 by current source 16. If necessary, a second zener diode D17 is connected in parallel with capacitor C. As in the circuit of FIG. 2, the current limiter is only used to match the input impedance of the circuit.
Although, most often, the galvanic isolation element is formed by an optocoupler, other circuits, for example with a transformer or a capacitor, may be encountered. In this case, the matching circuit is associated with an oscillator.
Most often, several interface circuits are associated on a same input/output card. Such a logic input/output card gathers, for example, 4, 8, 16, or 32 inputs.
A disadvantage common to conventional solutions is the necessary use of a protection resistor R between the sensor and the interface circuit. This resistor generates a dissipation which is to be multiplied by the number of logic inputs.
The circuits of FIGS. 2 and 3 form so-called “rail-to-rail” circuits, in which the two supply terminals are connected by diodes. A problem which is posed in such circuits is that in the presence of an overload, said overload is sent onto the supply voltage which is, conversely, generally desired to be stabilized.
An additional constraint of current-limiting circuits to which the present invention more specifically applies is that if the current flowing through the sensor is less than a given current, the output logic state must remain at zero. In other words, the optocoupler must remain off for a current un under a given threshold. In practice, standards set this threshold to a few milliamperes (for example, 1.5 milliampere).